libglnx porting: Drop uses of gs_file_openat_noatime
authorColin Walters <walters@verbum.org>
Wed, 15 Jun 2016 01:55:40 +0000 (21:55 -0400)
committerAtomic Bot <atomic-devel@projectatomic.io>
Tue, 21 Jun 2016 18:24:17 +0000 (18:24 +0000)
We're not really doing the "noatime" thing anymore.

Closes: #341
Approved by: jlebon

src/libostree/ostree-repo.c

index 81fc719f6ab965b084b72793760655781c88d6ba..843a648905c5b461489430b3d959b884d951863a 100644 (file)
@@ -2837,9 +2837,12 @@ ostree_repo_load_file (OstreeRepo         *self,
                */
               if (S_ISLNK (mode) || out_input)
                 { 
-                  if (!gs_file_openat_noatime (self->objects_dir_fd, loose_path_buf, &fd,
-                                               cancellable, error))
-                    goto out;
+                  fd = openat (self->objects_dir_fd, loose_path_buf, O_RDONLY | O_CLOEXEC);
+                  if (fd < 0)
+                    {
+                      glnx_set_error_from_errno (error);
+                      goto out;
+                    }
                 }
 
               if (S_ISREG (mode) && out_input)
@@ -2876,9 +2879,12 @@ ostree_repo_load_file (OstreeRepo         *self,
                 {
                   glnx_fd_close int fd = -1;
 
-                  if (!gs_file_openat_noatime (self->objects_dir_fd, loose_path_buf, &fd,
-                                               cancellable, error))
-                    goto out;
+                  fd = openat (self->objects_dir_fd, loose_path_buf, O_RDONLY | O_CLOEXEC);
+                  if (fd < 0)
+                    {
+                      glnx_set_error_from_errno (error);
+                      goto out;
+                    }
 
                   if (out_xattrs)
                     {